(function() {
	const response = {
		type: 'page',
		title: '已提交的入库申请',

		//顶部工具栏添加刷新按钮
		"toolbar": [
			{
				"type": "button",
				"label": "刷新",
				"onEvent": {
					"click": {
						"actions": [
							{
								"actionType": "refresh"
							}
						]
					}
				},
				"id": "u:921a0efbfa70"
			}
		],
		body:[
			{
				type: "crud",
				syncLocation: false,
				api: "post:/assetManager/amGetAssetImport",
				"autoFillHeight": true,
				loadDataOnce: true,
				"source": "${items | filter:assetId:match:assetFilter|filter:repositoryId:match:classesFilter" +
					"|filter:isComplete:match:isCompleteFilter" +
					"|filter:result:match:resultFilter}",
				"filter": {
					"title": "条件搜索",
					"body": [
						{
							"type": "input-text",
							"name": "assetFilter",
							"label": "资产id"

						},
						{
							"type": "input-text",
							"name": "classesFilter",
							"label": "仓库id"
						},
						{
							"type": "select",
							"label": "入库进度",
							"name": "resultFilter",
							"size": "md",
							"clearable": "true",
							"options": [
								{
									"label": "创建入库申请",
									"value": "创建入库申请"
								},
								{
									"label": "入库审批通过",
									"value": "入库审批通过"
								},
								{
									"label": "入库审批失败",
									"value": "入库审批失败"
								}
							]
						},
						{
							"type": "select",
							"label": "申请状态",
							"name": "isCompleteFilter",
							"clearable": "true",
							"options": [
								{
									"label": "已完成",
									"value": "完成"
								},
								{
									"label": "正在进行",
									"value": "正在进行"
								}
							]
						}
					]
				},
				columns:[
					{
						name: "assetId",
						label: "资产编号"
					},
					{
						name: "repositoryId",
						label: "资产目标仓库id"
					},
					{
						name: "assetManagerId",
						label: "资产管理员id"
					},
					{
						name: "createTime",
						"type": "date",
						"fromNow": true,//输出现在距离具体日期还有多久
						label: "申请时间"
					},
					{
						name: "result",
						label: "入库进度"
					},
					{
						name: "isComplete",
						label: "申请状态"
					}

				]


			}
		]

	}

	window.jsonpCallback && window.jsonpCallback(response);
})();
